#define _CRT_SECURE_NO_WARNINGS 1

#include "stack.h"

void test()
{
	Stack stack;

	STInit(&stack);

	STPush(&stack, 1);
	STPush(&stack, 2);
	STPush(&stack, 3);
	STPush(&stack, 4);

	printf("|%d|\n\n", STTop(&stack));

	while (!STEmpty(&stack))
	{
		printf("|%d|\n", STTop(&stack));
		STPop(&stack);
	}
	
	STDestroy(&stack);
}

int main()
{
	test();
	return 0;
}